<?php $comment = $form->getObject() ?>
<h1><?php echo $form->isNew() ? 'New' : 'Edit' ?> Comment</h1>

<form action="<?php echo url_for('comment/update'.(!$form->isNew() ? '?id='.$comment->get('id') : '')) ?>" method="post" <?php $form->isMultipart() and print 'enctype="multipart/form-data" ' ?>>
  <table>
    <tfoot>
      <tr>
        <td colspan="2">
          &nbsp;<a href="<?php echo url_for('comment/index') ?>">Cancel</a>
          <?php if (!$form->isNew()): ?>
            &nbsp;<?php echo link_to('Delete', 'comment/delete?id='.$comment->get('id'), array('post' => true, 'confirm' => 'Are you sure?')) ?>
          <?php endif; ?>
          <input type="submit" value="Save" />
        </td>
      </tr>
    </tfoot>
    <tbody>
      <?php echo $form ?>
    </tbody>
  </table>
</form>
